

import Vue from 'vue'
import Router from 'vue-router'
import Home from './pages/Home'
import Index from './pages/Index'
import Detail from './pages/Detail'
import Classify from './pages/Classify'
import Recommend from './pages/Recommend'
import Chat from './pages/Chat'
import My from './pages/My'

Vue.use(Router);


export default new Router({
    routes: [
        {
            path: '/',
            name: 'home',
            component: Home,
            redirect: 'Index',
            children: [
                {
                    path: '/Index',
                    name: 'index',
                    component: Index
                }
            ]
        },
        {
            path: '/Detail/:id',
            name: 'detail',
            component: Detail,
        },
        {
            path: '/Classify',
            name: 'classify',
            component: Classify,
        },
        {
            path: '/Recommend',
            name: 'recommend',
            component: Recommend,
        },
        {
            path: '/My',
            name: 'my',
            component: My,
        },
        {
            path: '/Chat',
            name: 'chat',
            component: Chat,
        }

    ]
})

